package com.ncs.cns.activity.fragment;

import android.os.Bundle;
import android.support.v4.app.Fragment;

import com.ncs.cns.business.db.DBHelper;
import com.ncs.cns.business.http.HttpHelper;
import com.ncs.cns.business.service.CommonService;
import com.ncs.cns.business.service.EventService;
import com.ncs.cns.business.service.ResourceService;
import com.ncs.cns.business.service.UserService;
import com.ncs.cns.business.service.UserSessionService;
import com.ncs.cns.framework.CnsApplication;

public class BaseFragment  extends Fragment{
	protected CnsApplication application = null;
	protected static final String EVENT_IS_MY="Y";
	protected static final String EVENT_IS_NOT_MY="N";
	
	protected HttpHelper httpHelper;
	protected CommonService commService;
	protected UserSessionService sessionService;
	protected UserService userService;
	protected ResourceService resourceService;
	protected EventService eventService;
	protected DBHelper dbHelper;
	protected String currentUserId;
	@Override
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		commService = new CommonService(getActivity());
		sessionService = new UserSessionService(getActivity().getApplicationContext());
		userService =new UserService(getActivity().getApplicationContext());
		resourceService = new ResourceService(getActivity().getApplicationContext());
		eventService = new EventService(getActivity());
		httpHelper = new HttpHelper(getActivity());
		dbHelper = new DBHelper(getActivity().getApplicationContext());
		//currentUserId = httpHelper.getCookie(CookieConstants.AUTO_LOGIN_CREDENTIAL);
		currentUserId = userService.getCurrentUser();
	}
	

}
